package com.weiwei.diancan.adapter;

import android.content.Context;
import android.view.View;

import com.weiwei.diancan.R;
import com.weiwei.diancan.bean.MainTest;

import java.util.List;

import weiwei.com.weiweilibrary.adapter.BaseSectionQuickAdapter;
import weiwei.com.weiweilibrary.holder.BaseViewHolder;
import weiwei.com.weiweilibrary.views.ToastUtil;

/**
 * Created by BMW on 2016/11/7.
 */
public class OpenDetailAdapter extends BaseSectionQuickAdapter<MainTest> {

    private Context context;

    public OpenDetailAdapter(List<MainTest> data, Context context) {
        super(R.layout.item_open_detail, R.layout.item_main_detail_group, data);
        this.context = context;
    }

    @Override
    protected void convertHead(BaseViewHolder helper, MainTest item) {

    }

    @Override
    protected void convert(BaseViewHolder helper, MainTest item, int postion) {
        helper.setOnClickListener(R.id.tv_add, v -> ToastUtil.showToast(context,"adddd"));
        helper.setOnClickListener(R.id.tv_jj, v -> ToastUtil.showToast(context,"ajjj"));
    }
}
